/**
 * Copyright (C) 2013 SHANGHAI VOLKSWAGEN, All rights reserved.
 * License version 1.0, a copy of which has been included with this.
 *
 * @File name：com.bwie.system.controller.SystemController
 * @Create on：2024/3/22
 * @Author：liuchang
 */
package com.bwie.system.controller;

import com.bwie.common.domain.User;
import com.bwie.common.result.Result;
import com.bwie.system.mapper.SystemMapper;
import com.bwie.system.service.SystemService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * <p>ClassName：SystemController</p >
 * <p>Description：</p >
 * <p>Author：liuchang</p >
 * <p>Date：2024/3/22</p >
 */
@RestController
@RequestMapping("/system")
public class SystemController {
    @Autowired
    private SystemService systemService;

    /*
     * 根据手机号查询用户信息
     * */
    @PostMapping("/findByPhone/{phone}")
    public Result<User> findByPhone(@PathVariable("phone") String phone){
        User user=systemService.findByPhone(phone);
        return Result.success(user);
    }
}
